package com.example.fileserver_API.Controller.Query;

import com.example.fileserver_API.Entity.Dto.PageParmar.PageParmar;
import com.example.fileserver_API.Entity.VO.APIResult;
import com.example.fileserver_API.Interfaces.IService.Query.IQueryservice;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/API/Query")
public class QueryController {

    @Autowired
    IQueryservice iQueryservice;

    /**
     * 统计查询获取数据
     * @param pageParmar 分页
     * @return APIResult
     */
    @PostMapping("/GetInfo")
    public APIResult GetInfo(@RequestBody PageParmar pageParmar){
        return iQueryservice.GetInfo(pageParmar);
    }
}
